<?php
class ALump_IndexController extends Alump_BaseController {
	
	private $_curPost = null;
	private $_pageno = 1;
	
	public static $PARAMS_COUNT = 4;
	
	
	function __construct($type, $pageno){
		parent::__construct($type);
		$this->_pageno = $pageno;
		$this->_data = ALump_Post::getRecentPosts();
		
		include $this->getTheme("index.php");
	}
	
	public function next(){
		$this->_curPost = $this->_data->next();
	}
	
	public function permalink(){
		$this->_curPost->permalink();
	}
	
	public function title(){
		$this->_curPost->title();
	}
	
	public function pageNav($prev = '&laquo;', $next = '&raquo;', $splitPage = 3, $splitWord = '...'){
		parent::_pageNav($prev, $next, $splitPage, $splitWord, $this->_pageno);
	}
}

?>